package com.example.demo.dao;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import com.example.demo.entity.Customer;

public interface CustomerRepository extends JpaRepository<Customer, Integer> {

	//nativeQuery = true  表示开启原生sql语句的使用
	@Query(value = "select * from customer  where id > ?1",nativeQuery = true) 
	public List<Customer> findGreaterThan(int id); 
}
